home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 5 / Skunkware 5.iso / man / cat.1 / tredir.1 < prev    next >
Text File  |  1995-07-25  |  14KB  |  331 lines

  1.  
  2.  
  3.  
  4.      TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))           UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV           TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))
  5.  
  6.  
  7.  
  8.      NNNNAAAAMMMMEEEE
  9.           trsh, tupload, tredir, txconn, tmon - clients to term
  10.  
  11.      SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.           _t_r_s_h [options] [command]
  13.  
  14.           _t_u_p_l_o_a_d [options] file ... [remote_directory]
  15.  
  16.           _t_r_e_d_i_r [options] {local_port [remotehost:]remote_port} ...
  17.  
  18.           _t_x_c_o_n_n [options]
  19.  
  20.           _t_m_o_n [options]
  21.  
  22.      DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  23.           These clients connect to a local _t_e_r_m(1) daemon and initiate
  24.           a communication link with the remote daemon and remote
  25.           processes.  _T_r_s_h runs an interactive shell or commands on
  26.           the remote system, _t_u_p_l_o_a_d transfers files from the local
  27.           system to the remote, _t_r_e_d_i_r redirects connections from
  28.           ports on the local system to ports on a remote system,
  29.           _t_x_c_o_n_n redirects X-server connections from the local system
  30.           to the remote, and _t_m_o_n prints summary information about a
  31.           _t_e_r_m link.
  32.  
  33.           As far as the clients are concerned, the link established by
  34.           _t_e_r_m(1) is completely symetric; the clients don't know which
  35.           system is your physically local system (the system you're
  36.           typing at) and which is physically remote.  From a client's
  37.           point of view, the local system is the one on which the
  38.           client is executing.  The remote system is the other system,
  39.           the one on which the client is not executing.
  40.  
  41.      UUUUSSSSAAAAGGGGEEEE
  42.           _t_r_s_h
  43.                With no arguments, _t_r_s_h is similar to _r_l_o_g_i_n(1).  An
  44.                interactive shell is started on the remote system.
  45.                Terminal features such as character echoing, line
  46.                editing, and window resizing are handled by a tty on
  47.                the remote system.  If a _c_o_m_m_a_n_d is given, it executes
  48.                on the remote system instead of the default shell.
  49.                Specifying _c_o_m_m_a_n_d without the -s option is primarily
  50.                useful for starting a non-default shell remotely.
  51.  
  52.                There is a single _t_r_s_h specific option:
  53.  
  54.                ----ssss   Use a simple connection.  This makes _t_r_s_h behave
  55.                     more like _r_s_h(1).  The specified _c_o_m_m_a_n_d is
  56.                     executed by a shell on the remote system.  Like
  57.                     _r_s_h(1), quoted shell metacharacters are
  58.                     interpreted remotely, so filename redirection,
  59.                     multiple commands, or pipes can be used remotely.
  60.  
  61.  
  62.  
  63.      Page 1                                           (printed 7/3/94)
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.      TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))           UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV           TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))
  71.  
  72.  
  73.  
  74.                     If no _c_o_m_m_a_n_d is given, the -s option is ignored.
  75.  
  76.                The -s option should almost always be used when a
  77.                _c_o_m_m_a_n_d is provided.  In particular, it should be used
  78.                if _t_r_s_h is part of a pipeline.  The only exception to
  79.                this rule is when remote terminal features are needed.
  80.  
  81.                _T_r_s_h differs from _r_l_o_g_i_n(1) and _r_s_h(1) in a couple of
  82.                significant ways.  First, the stdout and stderr of the
  83.                remote shell or command are both directed to the local
  84.                stdout.  Second, the connection is broken as soon as a
  85.                local end-of-file occurs.  This means that any output
  86.                generated by the remote system after EOF is lost.  For
  87.                example,
  88.  
  89.                    trsh -s wc < /etc/passwd
  90.  
  91.                runs the remote _w_c(1) command on the contents of the
  92.                local /etc/passwd, but will not produce any output.
  93.  
  94.           _t_r_e_d_i_r
  95.                _T_r_e_d_i_r accepts pairs of port numbers, the first of each
  96.                being the local port number to redirect, and the second
  97.                the remote port to redirect into. _T_r_e_d_i_r will also
  98.                accept a hostname with each of the second port numbers.
  99.                For example,
  100.  
  101.                   tredir 119 my.nntp.host:119
  102.  
  103.                can be run on the non-internet side of the link.  Then,
  104.                any local program that connects to port 119 (like an
  105.                NNTP newsreader), will be connected to port 119 on
  106.                my.nntp.host.  _T_r_e_d_i_r becomes a background daemon once
  107.                it has successfully established the local port. More
  108.                than one port can be redirected at once with a single
  109.                _t_r_e_d_i_r.  For example,
  110.  
  111.                   tredir 119 my.nntp.host:119 4000 remote.home:23
  112.  
  113.                would redirect ports 119 and 4000, 119 to the nntp port
  114.                on my.nntp.host, and port 4000 to the login port on
  115.                remote.host.
  116.  
  117.           _t_u_p_l_o_a_d
  118.                _T_u_p_l_o_a_d takes a list of local file names to upload. If
  119.                there is more than one name, then the last name is
  120.                checked to see if it matches a remote directory.  If it
  121.                does match a remote directory, the files are uploaded
  122.                to this directory.  If a remote file exists, and is
  123.                smaller than the local file, tupload will assume that
  124.                it was a previous upload that got aborted, and will
  125.                attempt to resume the upload.   Tupload specific
  126.  
  127.  
  128.  
  129.      Page 2                                           (printed 7/3/94)
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.      TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))           UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV           TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))
  137.  
  138.  
  139.  
  140.                options are.
  141.  
  142.                ----ffff   Tells _u_p_l_o_a_d to not do any possible resumptions.
  143.                     Always overwrite the remote file.
  144.  
  145.                ----uuuu   Unlink the local file after a succesful upload.
  146.  
  147.                ----vvvv   Verbose mode. Will write out the number of bytes
  148.                     transfered, the name of the remote file, and the
  149.                     CPS rate. Two 'v's will produce more output.
  150.  
  151.                ----qqqq   Quiet mode. Tupload will not write out any
  152.                     messages.
  153.  
  154.                ----aaaassss <<<<rrrreeeemmmmooootttteeee____ffffiiiilllleeee>>>>
  155.                     Any of the local _f_i_l_e names may be followed by the
  156.                     -as <remote_file> option to specify a new name for
  157.                     the remote copy of the file. By default the remote
  158.                     file will have the same name as the local file.
  159.  
  160.           _t_x_c_o_n_n
  161.                _T_x_c_o_n_n establishes an X screen port on the system it is
  162.                run on.  Connections to that screen will be redirected
  163.                to the X server on the other system.  If your DISPLAY
  164.                environment variable is set, _t_x_c_o_n_n will try to use the
  165.                screen number given by DISPLAY.  _T_x_c_o_n_n prints the
  166.                number of the screen it actually establishes in a
  167.                format suitable for re-setting your DISPLAY variable.
  168.                The recommended method of starting _t_x_c_o_n_n and setting
  169.                you DISPLAY variable at the same time is to run
  170.  
  171.                    setenv DISPLAY `hostname``txconn`
  172.  
  173.                from csh and related shells, or
  174.  
  175.                    export DISPLAY=`hostname``txconn`
  176.  
  177.                from sh and related shells.  _T_x_c_o_n_n becomes a
  178.                background daemon once it has successfully established
  179.                the port.
  180.  
  181.           _t_m_o_n _T_m_o_n periodically queries the _t_e_r_m daemon for
  182.                information about the number of clients and the data
  183.                flow-rate of the channels.  It updates its output on
  184.                the terminal it is running in.
  185.  
  186.      GGGGLLLLOOOOBBBBAAAALLLL OOOOPPPPTTTTIIIIOOOONNNNSSSS
  187.           The following options are accepted by all _t_e_r_m clients
  188.  
  189.           ----tttt <server>
  190.                Specifies which term daemon socket to connect to
  191.                (~/.term/socket<server>).  This is useful if you have
  192.  
  193.  
  194.  
  195.      Page 3                                           (printed 7/3/94)
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.      TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))           UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV           TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))
  203.  
  204.  
  205.  
  206.                specific socket names for connections to specific
  207.                remote hosts, or if you have multiple terms using
  208.                different serial connections.
  209.  
  210.           ----rrrr   Specifies a raw link (no compression).
  211.  
  212.           ----cccc   Specifies a compressing link.
  213.  
  214.           ----pppp <number>
  215.                Specifies priority for this link.  A client with higher
  216.                priority will be able to send all its data before lower
  217.                priority clients.  This may be changed in future
  218.                releases. The priority of _t_r_s_h defaults to 2 and
  219.                _t_u_p_l_o_a_d defaults to -2.  All other clients default to
  220.                zero.
  221.  
  222.      EEEEXXXXAAAAMMMMPPPPLLLLEEEESSSS
  223.           Some simple, contrived examples:
  224.  
  225.               trsh
  226.  
  227.           This establishes an interactive shell on the remote machine.
  228.           The connection is maintained until you exit the remote
  229.           shell.
  230.  
  231.               trsh -s who
  232.  
  233.           prints out a list of current users of the remote machine.
  234.  
  235.               ls -li | awk '{print $1, $5}' | trsh -s plot
  236.  
  237.           will generate a scatter plot of file size vs inode.  Most
  238.           likely this would be run on the physically remote system to
  239.           produce local graphical output about the files on the remote
  240.           system.
  241.  
  242.               tupload -vv -r lin-0.99.3.tar.Z -as lin993.tar.Z /new
  243.  
  244.           This will upload the local file 'lin-0.99.3.tar.Z' to the
  245.           remote system with the name '/new/lin993.tar.Z'. It will
  246.           resume an upload if there is an existing /new/lin993.tar.Z,
  247.           and will writeout the CPS and bytes transfered every 2K. It
  248.           will not do compression on the way.
  249.  
  250.               tredir 6667 munagin.ee.mu.oz.au:6500 9017 17
  251.  
  252.           This will map any connections to port 6667 on your local
  253.           host to port 6500 on munagin.ee.mu.oz.au and any connections
  254.           on your local host to port 9017 to port 17 on the remote
  255.           machine.  So if you do 'telnet 0 6667' locally, you will be
  256.           connected to port 6500 on munagin, and if you do 'telnet 0
  257.           9017', you will be connected to port 17 on the remote
  258.  
  259.  
  260.  
  261.      Page 4                                           (printed 7/3/94)
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.      TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))           UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV           TTTTEEEERRRRMMMM____CCCCLLLLIIIIEEEENNNNTTTTSSSS((((1111))))
  269.  
  270.  
  271.  
  272.           machine.
  273.  
  274.           Let's say the physically remote machine, earlobe.mit.edu, is
  275.           on the internet.  You can establish a port on earlobe which
  276.           will allow anyone on the internet to telnet to your
  277.           physically local, non-internet machine.  On the local
  278.           machine you could type
  279.  
  280.               trsh -s tredir 4000 23
  281.  
  282.           Alternatively, if you already have an interactive shell on
  283.           the remote machine you could just run the tredir command
  284.           from that shell.  In either case, once the tredir daemon is
  285.           running, users typing
  286.  
  287.               telnet earlobe.mit.edu 4000
  288.  
  289.           from any internet host will get a login prompt from your
  290.           physically local machine.
  291.  
  292.      BBBBUUUUGGGGSSSS
  293.           None of the local environment is propogated by _t_r_s_h, so the
  294.           remote TERM variable is likely to be wrong.  If the remote
  295.           command for 'trsh -s <command>' doesn't consume its input
  296.           fast enough, the channel can lose data.  _T_r_s_h breaks the
  297.           channel as soon as the local EOF is received, thus losing
  298.           any final output from the remote process.  _T_m_o_n gives bogus
  299.           output on some machines (e.g. NeXT).
  300.  
  301.      SSSSEEEEEEEE AAAALLLLSSSSOOOO
  302.           _t_e_r_m(1), _t_e_r_m__s_e_t_u_p(1).
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.  
  325.  
  326.  
  327.      Page 5                                           (printed 7/3/94)
  328.  
  329.  
  330.  
  331.